<template>
  <div>
    <div ref="testRef" v-show-tooltip="moreThenLengthWOrd"
         :style="{width: testWidth+ 'px'}"
         class="test">4564654654
    </div>
    <div style="width: 60px" class="test">
      <div ref="testRef2" v-show-tooltip="55555">4564654654</div>
    </div>
    <div ref="testRef3" v-show-tooltip="666666">4564654654</div>
    <div ref="testRef4" v-show-tooltip="4545456465" class="test">4564654654</div>
    <div>结果：{{result}}</div>
  </div>
</template>
<script>
import ShowTooltip from "@localModules/ZhiXinLib/directive/VshowTooltip/VshowTooltip";

export default {
  name: 'ChildTestShowTip',
  directives:{
    ShowTooltip
  },
  props: {
    moreThenLengthWOrd: {
      type:String
    },
    result: {},
    testWidth: {}
  }
}
</script>
<style scoped lang="scss">
.test {
  width: 50px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
</style>
